Open
Conversation
Member
Author
|
Note: This conflicts with #2469 due to the use of materialized views. |
Users that changed their username to something like `User`, were unable to login because the username is downcased on routes/login.cr
syeopite
requested changes
Mar 26, 2025
SamantazFox
reviewed
Apr 5, 2025
| "accounts_username_required_field": "Username is a required field", | ||
| "accounts_username_empty": "Username cannot be empty", | ||
| "accounts_username_is_the_same": "This is your username, use another one", | ||
| "accounts_username_taken": "Username is already taken, use another one" |
Member
There was a problem hiding this comment.
We'd need to use UUIDs of some sort to differenciate accounts at some point. I'm worried that account name switching could be used to find if someone else is registered on this instance.
Member
Author
There was a problem hiding this comment.
I'm worried that account name switching could be used to find if someone else is registered on this instance.
That is already possible in the login page, if you insert a registered user with a wrong password it will return Wrong username or password.
Unless you are referring to another case I'm missing
syeopite
requested changes
Apr 5, 2025
Co-authored-by: syeopite <70992037+syeopite@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Tested and it works fine. I made this for people that want to change their username on public Invidious instances without having to create a new account or having to contact the instance maintainer to change their username. It also updates the materialized views sha256 ids, so if a user changed their account name from
usertouser2and a new user registers on the instance with the usernameuser, there shouldn't be a relation collision (when the collision happens, this is displayed:relation "subscriptions_sha256" already exists)Tested:
user1touser2, subscriptions are maintained across username changesuser2back touser1works well.user1anduser1)